package com.yygo.model.vo;

import com.yygo.model.Feedback;
import com.yygo.util.DateUtil;

import java.util.Date;

/**
 * Created by tiansha on 2015/7/23.
 */
public class FeedbackVO {
    private String time;
    private String operator;
    private String reqStatus;
    private String feedbackType;
    private String feedbackStatus;
    private String content;
    private boolean requireBack;
    private String number;
    private Long id;

    public FeedbackVO() {
        Date date = new Date();
        time = DateUtil.getDateTime("MM/dd/yyyy", date);
    }

    public FeedbackVO(Feedback feedback) {
        setId(feedback.getLoanRequest().getId());
        setNumber(feedback.getLoanRequest().getNumber());
        time = DateUtil.getDateTime("MM/dd/yyyy", feedback.getTime());
        setOperator(feedback.getFeedbackRequester().getUsername());
        setFeedbackType(feedback.getFeedbackType().toString());
        setRequireBack(feedback.isRequireBack());
        setContent(feedback.getContent());
        setFeedbackStatus(feedback.getFeedbackStatus().toString());
    }

    public Long getId() {
        return id;
    }

    public void setId(Long id) {
        this.id = id;
    }

    public String getTime() {
        return time;
    }

    public void setTime(String time) {
        this.time = time;
    }

    public String getOperator() {
        return operator;
    }

    public void setOperator(String operator) {
        this.operator = operator;
    }

    public String getReqStatus() {
        return reqStatus;
    }

    public void setReqStatus(String reqStatus) {
        this.reqStatus = reqStatus;
    }

    public String getFeedbackType() {
        return feedbackType;
    }

    public void setFeedbackType(String feedbackType) {
        this.feedbackType = feedbackType;
    }

    public String getContent() {
        return content;
    }

    public void setContent(String content) {
        this.content = content;
    }

    public boolean isRequireBack() {
        return requireBack;
    }

    public void setRequireBack(boolean requireBack) {
        this.requireBack = requireBack;
    }

    public String getFeedbackStatus() {
        return feedbackStatus;
    }

    public void setFeedbackStatus(String feedbackStatus) {
        this.feedbackStatus = feedbackStatus;
    }

    public String getNumber() {
        return number;
    }

    public void setNumber(String number) {
        this.number = number;
    }
}
